package HLLibClasses;

import HLCode.HLClassManager;
import HLCode.HLLibClass;
import HLCode.HLObject;
import HLLib.base.HLList;
import HLLib.game.HLSpriteInfoManagerMesh;

public class HLClassSpriteInfoManagerMesh extends HLLibClass {
    public HLClassSpriteInfoManagerMesh(HLClassManager owner) {
        super(owner);
    }

    public HLObject NewObject() {
        return new HLSpriteInfoManagerMesh();
    }

    public void Execute(HLObject self, int index, HLObject args, HLObject resultOwnerObject, int resultIndex) {
        switch (index) {
        case 0: {
            ((HLSpriteInfoManagerMesh) self).RemoveAt(args.GetInt(0), args.GetInt(1));
            break;
        }
        case 1: {
            ((HLSpriteInfoManagerMesh) self).Refresh((HLList)args.GetObject(0), args.GetInt(0), args.GetInt(1));
            break;
        }
        case 2: {
            if (resultOwnerObject == null) {
                ((HLSpriteInfoManagerMesh) self).GetNewSpriteInfosEX(args.GetInt(0), args.GetInt(1), args.GetInt(2), args.GetInt(3));
            } else {
                resultOwnerObject.SetObject(resultIndex, ((HLSpriteInfoManagerMesh) self).GetNewSpriteInfosEX(args.GetInt(0), args.GetInt(1), args.GetInt(2), args.GetInt(3)));
            }
            break;
        }
        case 3: {
            if (resultOwnerObject == null) {
                ((HLSpriteInfoManagerMesh) self).GetNewSpriteInfosFirst(args.GetInt(0), args.GetInt(1), args.GetInt(2), args.GetInt(3));
            } else {
                resultOwnerObject.SetObject(resultIndex, ((HLSpriteInfoManagerMesh) self).GetNewSpriteInfosFirst(args.GetInt(0), args.GetInt(1), args.GetInt(2), args.GetInt(3)));
            }
            break;
        }
        case 4: {
            if (resultOwnerObject == null) {
                ((HLSpriteInfoManagerMesh) self).GetNewSpriteInfos(args.GetInt(0), args.GetInt(1));
            } else {
                resultOwnerObject.SetObject(resultIndex, ((HLSpriteInfoManagerMesh) self).GetNewSpriteInfos(args.GetInt(0), args.GetInt(1)));
            }
            break;
        }
        case 5: {
            ((HLSpriteInfoManagerMesh) self).Clear();
            break;
        }
        }
    }
}
